package com.water_work_form.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.Version;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Table;

/**
 * <p>
 * 基础表——计算公式
 * </p>
 *
 * @author xuke
 * @since 2023-08-01
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Table(name = "basic_formula")
@ApiModel(value="BasicFormula对象", description="基础表——计算公式")
public class BasicFormula implements Serializable {

    private static final long serialVersionUID=1L;

    @TableId(value = "id", type = IdType.INPUT)
    private Long id;

    @ApiModelProperty(value = "公式号码")
    private Integer num;

    @ApiModelProperty(value = "项目")
    @Column(unique = true)
    private String name;

    @ApiModelProperty(value = "公式内容")
    private String formulaContent;

    @ApiModelProperty(value = "公式说明")
    private String formulaDescription;

    @Override
    public String toString() {
        return "{\"name\":\"" + name + "\",\"formulaContent\":\"" + formulaContent + "\",\"formulaDescription\":\"" + formulaDescription + "\"}";
    }

}
